package ldh.im.web.exception;

public class ErrorStatusException extends RuntimeException {

    private ErrorStatus errorStatus;

    public ErrorStatusException(ErrorStatus errorStatus) {
        this.errorStatus = errorStatus;
    }

    public ErrorStatusException(ErrorStatus errorStatus, String message) {
        super(message);
        this.errorStatus = errorStatus;
    }

    public ErrorStatusException(ErrorStatus errorStatus, String message, Throwable cause) {
        super(message, cause);
        this.errorStatus = errorStatus;
    }

    public ErrorStatusException(ErrorStatus errorStatus, Throwable cause) {
        super(cause);
        this.errorStatus = errorStatus;
    }

    public ErrorStatusException(ErrorStatus errorStatus, String message, Throwable cause, boolean enableSuppression, boolean writableStackTrace) {
        super(message, cause, enableSuppression, writableStackTrace);
        this.errorStatus = errorStatus;
    }

    public ErrorStatus getErrorStatus() {
        return errorStatus;
    }
}
